/**
 * Class: OpenLayers.Control.AddCustomMarker
 * 添加自定义标注
 * 继承自: - <OpenLayers.Control>
 * @requires extend/Control/CustomPointMarker.js
 */

OpenLayers.Control.CustomLineMarker = OpenLayers.Class(OpenLayers.Control.CustomPointMarker,{
	/**
	 * 标题
	 * @property title
	 * @type {String}
	 */
	title : "线标注",
	/**
	 * 标注类型
	 * @property markerType
	 * @type {String}
	 */
	markerType: "line",
	
	/**
	 * Method: initialize 初始化
	 */
	initialize : function(options) {
		OpenLayers.Control.CustomPointMarker.prototype.initialize.apply(this,arguments);
		
		this.handler = new OpenLayers.Handler.Path(this, {
            done: this.openInfoPopup
        });
	},

	/**
	 * Method: activate 控件被触发时设置鼠标手势
	 */
	activate : function() {
		OpenLayers.Control.CustomPointMarker.prototype.activate.apply(this,arguments);
		
        var cursor = "url("+OpenLayers.Util.getRootPath()+"img/line.ico) 5 10,auto";
        this.map.layerContainerDiv.style.cursor = cursor;
		
	},
	
	CLASS_NAME : "OpenLayers.Control.CustomLineMarker"
});